//===================================================================================
// Microsoft patterns & practices
// Composite Application Guidance for Windows Presentation Foundation and Silverlight
//===================================================================================
// Copyright (c) Microsoft Corporation.  All rights reserved.
// THIS CODE AND INFORMATION IS PROVIDED "AS IS" WITHOUT WARRANTY
// OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING BUT NOT
// LIMITED TO THE IMPLIED WARRANTIES OF MERCHANTABILITY AND
// FITNESS FOR A PARTICULAR PURPOSE.
//===================================================================================
// The example companies, organizations, products, domain names,
// e-mail addresses, logos, people, places, and events depicted
// herein are fictitious.  No association with any real company,
// organization, product, domain name, email address, logo, person,
// places, or events is intended or should be inferred.
//===================================================================================
using System;

namespace Microsoft.Practices.Prism.Regions
{
	/// <summary>
	/// Provides a way for objects involved in navigation to determine if a navigation request should continue.
	/// </summary>
	public interface IConfirmNavigationRequest : INavigationAware
	{
		/// <summary>
		/// Determines whether this instance accepts being navigated away from.
		/// </summary>
		/// <param name="navigationContext">The navigation context.</param>
		/// <param name="continuationCallback">The callback to indicate when navigation can proceed.</param>
		/// <remarks>
		/// Implementors of this method do not need to invoke the callback before this method is completed,
		/// but they must ensure the callback is eventually invoked.
		/// </remarks>
		void ConfirmNavigationRequest(NavigationContext navigationContext, Action<bool> continuationCallback);
	}
}